# 定义函数
# def func_demo() :
#     #函数体
#     print("这是美好的一天")
# func_demo()

#定义加法
# def sum(a, b):
#     result = a + b
#     print(result)
#     #函数返回值
#     return result, a, b
# c = sum(1, 2)
# print(c)

# *args **kwargs
# fruit = [("apple", 5.5), ("banana", 3.8), ("lemon", 6.58)]
# print(fruit)
# #指定规则进行排序
# #lambda x:(x[1]) 返回列表中每个元组中第二个元素
# fruit.sort(key=lambda x:(x[1]))
# print(fruit)

#飞机
# class airplan:
#     name = ""
#     color = ""
#
#     def set_color(self, color):
#         self.color = color
#         print(f"飞机的颜色:{self.color}")
#     def set_name(self, name):
#         self.name = name
#         print(f"飞机的名字:{self.name}")
# #民用飞机
# class civilairplan(airplan):
#     def load_person(self, num):
#         print(f"民用飞机载客人数：{num}")
#
# civilair = civilairplan()
# civilair.set_color("民用飞机的颜色：红色")
# civilair.load_person(100)

#对象
# air1 = airplan()
# air1.set_name("第一架飞机")
# air1.set_color("红色")
#
# air2 = airplan()
# air2.set_name("第二架飞机")
# air2.set_color("灰色")

# import random
# #
# # print(random.randint(1,10))
# import os
# #help(os)
# print(dir(os))

# import random
# def solution() -> list:
#     # 0317 扑克荷官
#     res = []
#     icons = ['H', 'C', 'D', 'S']
#     random.shuffle(icons)
#     for i in icons:
#         nums = [i for i in range(1, 14)]
#         random.shuffle(nums)
#         for j in nums:
#             tmp = (i, j)
#             res.append(tmp)
#     print(res)
#     return res
#
# deck1 = solution()
# deck2 = solution()
#
# assert len(set(deck1)) == 52
# assert len(set(deck2)) == 52
# assert deck1 != deck2
# assert sorted(deck1) == sorted(deck2)